;;; lisp-settings.el --- gww<qq563066990@gmail.com>

;; Copyright (C) 2013  gww

;; Author: gww <gww@192.168.0.171>
;; Keywords: lisp

;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.

;; This program is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;; GNU General Public License for more details.

;; You should have received a copy of the GNU General Public License
;; along with this program.  If not, see <http://www.gnu.org/licenses/>.

;;; Commentary:

;; 

;;; Code:
(setq inferior-lisp-program "/usr/local/src/ccl/scripts/ccl64")

(defun show-lisp-repl()
  (interactive)
  (setq temp-buffer-name (buffer-name (current-buffer)))
  ;;(show-output-window "*slime-repl ccl*")
  (if (get-buffer "*slime-repl ccl*")
      (switch-to-buffer-other-window "*slime-repl ccl*")
    (slime))
  (switch-to-buffer-other-window temp-buffer-name)
  (show-output-window "*slime-repl ccl*" t))

(defun lisp-key-bindings()
  (message "lisp-key-bindings"))

;;(define-key lisp-mode-map [f1] '(lambda () (show-output-window "*slime-repl sbcl*")))


(add-hook
 'lisp-mode-hook
 '(lambda () 
    (define-key lisp-mode-map [f1] 'show-lisp-repl)
    (define-key lisp-mode-map (kbd "C-c z")  'show-lisp-repl) ))

(eval-after-load "lisp-mode"
  '(progn
     (require 'mod-slime)
     (slime-mode)
     (lisp-key-bindings)))

(provide 'mod-ccl)
;;; lisp-settings.el ends here

